package com.nb.controller.hospital;


import com.nb.result.Result;
import com.nb.service.HospitalService;
import com.nb.vo.hospital.HospitalInfoVO;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/*
* 医院相关接口
* */
@Slf4j
@RestController
@RequestMapping("/api/hospital")
public class HospitalController {

    @Autowired
    private HospitalService hospitalService;

    //获取医院信息
    @GetMapping("/info")
    public Result<HospitalInfoVO> getHospitalInfo(){
        log.info("获取医院信息");
        HospitalInfoVO hospitalInfoVO = hospitalService.getHospitalInfo();
        return Result.success(hospitalInfoVO);
    }

}
